<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <!-- 请将  [“关羽”,“张飞”,“马超”,“赵云”,“黄忠”,“刘备”,“姜维”]; 数组里的元素依次打印到控制台 -->
<script>   
    var arr = ["关羽", "张飞", "马超", "赵云", "黄忠", "刘备", "姜维"];
    for(var i=0;i<arr.length;i++)    {
        console.log(arr[i]);
        document.write(arr[i]+"<br>");
        }

</script>
</body>
</html>